---
title: clsTaskPriorityCode
summary: API reference for clsTaskPriorityCode.
status: draft
owner: SAIF Documentation
last_reviewed: 2026-08-21
library: SAIF.Business.Tasks
reference_type: embedded
---

# clsTaskPriorityCode

`clsTaskPriorityCode` represents a single, read-only row of `TASK_PRIORITY_CODE`, exposing the code's mapped `TaskPriority` enum value alongside its description.

## Purpose
- Load and expose one priority code, its description, and its corresponding `TaskPriority` enum value ([SQL-009](../../sql/SQL-009-select-task-priority-code.md)).

## Context
- Namespace: `SAIF.Business.Tasks`
- Assembly/package: `SAIF.Business.Tasks` (embedded in the `LegalMaintenance` web deployment)

## Public members
| Member | Signature | Purpose |
| --- | --- | --- |
| `Code` | `ReadOnly Property Code As String` | The priority code value (`TASK_PRIORITY_CODE.CODE`). |
| `Description` | `ReadOnly Property Description As String` | Human-readable description (`TASK_PRIORITY_CODE.CODE_DESCR`). |
| `TaskPriority` | `ReadOnly Property TaskPriority As TaskPriority` | The `TaskPriority` enum value this code maps to. |
| `GetCode` | `Shared Function GetCode(dpi As IDataPortalInfo, inCode As String) As clsTaskPriorityCode` | Factory/retrieval entry point that loads a single priority code by value ([SQL-009](../../sql/SQL-009-select-task-priority-code.md)). |
| `Criteria` | `Friend Class Criteria` (nested, implements `IBusinessCriteria`) | Read-only criteria for this code table; write-SQL properties throw `ApplicationException(clsConstants.Messages.InvalidSQLProperty)` ([BR-023](../../business-rules.md#br-023-code-tables-are-read-only-reference-data)). |

## Behavioral notes
- The class is `<Serializable()>`, consistent with remoting/session persistence of BOF objects across the web tier*.

## Constraints and usage notes
- Any attempt to use `CreateSQL`/`InsertSQL`/`UpdateSQL`/`DeleteSQL` on this type's `Criteria` throws `ApplicationException(clsConstants.Messages.InvalidSQLProperty)` ([BR-023](../../business-rules.md#br-023-code-tables-are-read-only-reference-data)).

> **Note:** Statements marked with * were inferred from code structure, naming conventions, or
> contextual evidence where direct confirmation was not available in source artifacts. Statements
> marked with ** could not be confirmed; treat as unknown until verified.

## Related documentation
- [API index](../index.md)
- [clsTaskPriorityCodeCollection](clsTaskPriorityCodeCollection.md)
- [Database tables](../../database-tables.md)

## Sources
- SAIF.Business.Tasks/clsTaskPriorityCode.vb
